#ifndef __MUSIC_H__  	//理解为 if not define MUSIC.h
#define __MUSIC_H__  	//如果没有定义MUSIC.h.,这里就定义一个MUSIC.h

#include <REGX52.H>		//引用单片机头文件

/****蜂鸣器****/
#define SPEED   500  	//四分音符500ms
sbit Buzzer = P1^0;		//蜂鸣器引脚定义
//sbit Buzzer = P2^0;		//蜂鸣器引脚定义

// 音符与索引对应表，P：休止符，L：低音，M：中音，H：高音，下划线：升半音符号#
#define P	0
#define L1	1
#define L1_	2	//Ctrl+shift+F可以替换变量字母
#define L2	3
#define L2_	4
#define L3	5
#define L4	6
#define L4_	7
#define L5	8
#define L5_	9
#define L6	10
#define L6_	11
#define L7	12
#define M1	13
#define M1_	14
#define M2	15
#define M2_	16
#define M3	17
#define M4	18
#define M4_	19
#define M5	20
#define M5_	21
#define M6	22
#define M6_	23
#define M7	24
#define H1	25
#define H1_	26
#define H2	27
#define H2_	28
#define H3	29
#define H4	30
#define H4_	31
#define H5	32
#define H5_	33
#define H6	34
#define H6_	35
#define H7	36

extern unsigned int code FreqTable[];	//用extern外部声明出去，在main.c中调用

/*乐谱变量名称*/
extern unsigned char code Music_HuaHai[];	            //《花海》
extern unsigned char code Music_Castle_in_the_Sky[];    //《天空之城》
extern unsigned char code Music_3[];                    //《勇气大爆发》
extern unsigned char code Auld_Lang_Syne[];             //《友谊地久天长》Auld Lang Syne
//extern unsigned char code Music_lbkch[];                //《离别开出花》
extern unsigned char code Music_chengdu[];              //《成都》
extern unsigned char code Music_xiaoxingxing[];         //《小星星》
/*标志位*/


/*函数*/
void Key_Scan(void);	//按键扫描

#endif